<template>
    <div class="container">
        <input :value="props.modelValue" @input="emit('update:modelValue', $event.target.value)"/>
        <Child :content="childContent"></Child>
    </div>

</template>

<script setup>
    import { computed } from 'vue';
    import Child from './Child.vue';
    const props = defineProps(['modelValue'])
    const emit = defineEmits(['update:modelValue'])
    const childContent = computed(()=>{
        return `Parent是${props.content}, Child是Parent的子组件`
    })
</script>
<style scoped>
    span {
        color: blue;
    }
</style>